The present invention relates to a network relaying apparatus and a network relaying method, or in particular to a network relaying apparatus including a router of a computer network system which is capable of searching at high speed for a destination of a packet input and a network relaying search method.
Generally, in a network system, a network relaying apparatus such as a router or a bridge is used for connecting a plurality of networks. The router checks the destination address of a packet received from a network or a subnet connected, determines the destination of the packet, and transfers the packet to a network or a subnet which is connected with the destination router or host.
FIG. 13 is a diagram showing a configuration of a conventional network relaying apparatus. In FIG. 13, a router 100 includes a routing manager (RM) 110, router buses 120, network interfaces (NIF) 130 and ports 140. Each port 140 is connected to an appropriate network 150.
Each network interface 130 receives a packet from a network connected to the port 140, and transmits the received packet through the router bus 120 to the routing manager 110. The routing manager 110 includes a routing table for holding the routing information, and using this routing information, determines the network 150 of the destination from the address of the packet received, and transmits the packet to the network interface 130 of the port 140 connected to the network 150. The network interface 130 that has received the packet from the routing manager 110 sends out the packet to the destination network 150. The routing manager 110 updates and maintains the routing information held in the routing table based on the header information of the packet received, and has the function of overall management of the router 100.
An explanation will be given of the route search process for searching for a port outputting the next address to which the packet is to be transferred upon receipt of the packet and outputting the packet. Normally, the route search uses a route search table (routing table) prepared from the component definition information and the information obtained by exchange between the routers. The routing table is for searching the information (next hop information) as to the output port, the next hop address and whether the network is directly connected or not with a set of the network address and the network mask length as a key.
As another conventional system, JP-A-05-199230(U.S. Pat. Ser. No. 5,434,863) discloses an internetwork system and a communication network system which can flexibly meet the size requirement of the network without adversely affecting the high-speed routing process. In these systems, a router manager and a plurality of routing accelerator modules are coupled to each other with a high-speed bus Also, each routing accelerator is connected with a plurality of independent communication ports. In these conventional systems, a plurality of the routing accelerators makes possible a high-speed routing and by adding the routing accelerators, the requirement for increasing the network size can be easily met.
In recent years, the demand has increased for the dynamic routing in which the relaying information for routing is dynamically generated, added, changed or deleted by recognizing the configuration of the network in operation. Specifically, the router requires the processing of the routing protocol (such as the Routing Information Protocol (RIP) or Open Shortest Path First (OSPF) included in TCP/IP protocols) for exchanging information on the network between the routers. Further, the processing of the network management protocol (such as Simple Network Management Protocol (SNMP) which is one of the TCP/IP protocols) for communication of the management information such as the performance of the router with a management master station on the network is performed unavoidably by the routing means in the prior art. This makes it impossible for the router to exhibit the relaying performance sufficiently. The conventional router, therefore, cannot easily meet the requirement of the high-speed lines such as the high-speed LAN (Local Area Network), the wide-band ISDN (Integrated Services Digital Network) and ATM (Asynchronous Transfer Mode) that have recently found practical applications.
Also, with the recent increase in the operating speed of the network, the data processing system used for the routers and bridges require a high processing speed of the network controller searching for a transfer destination route from a memory. Further, considering the processor contention for memory access, the conventional routers limit the number of network controllers to absorb the reduced performance caused by the memory access contention or, though low in cost effectiveness, unavoidably use a high-speed memory or a dual-port memory accessible from the processors or the network controller asynchronously. Also, the route search in the conventional router is carried out mainly in software, thereby making high speed execution of the routing process difficult.
An object of the present invention is to provide a network relaying apparatus and method for high speed routing while assuring a high communication quality (QoS), a high reliability and security.
Another object of the invention is to provide a network relaying apparatus and method for high speed packet routing and packet transfer by executing the hardware processing for each function block including a transfer engine and a search engine.
Still another object of the invention is to provide a network relaying apparatus and method for high-speed routing by dividing the routing process into the receiving process, the transmission process, the input search process and the output search process with required tables used independently of each other.
Yet another object of the invention is to provide a relaying apparatus and method for realizing a higher speed by executing each process by pipelining.
Other objects, features and advantages of the present invention will become apparent from the following description of the embodiments of the invention taken in conjunction with the accompanying drawings.
According to one aspect of the invention, here is provided a network relaying apparatus connecting a plurality of networks for outputting the packets input from the networks, to the next transfer destination based on the route information, comprising:
at least a network interface connected to the networks for controlling the interface with the networks;
at least a routing processor connected to one or a plurality of the network interfaces for routing the packets input from the network interfaces;
a routing manager for managing the internal components of the system; and
a connector for connecting the routing manager and each of a plurality of the routing processors;
wherein the routing processors each include:
a packet buffer for storing an input packet;
a high-speed readable and writable header memory accessible asynchronously with the packet buffer and adapted for storing the header information including the header and the internal header of the input packet;
a route table for storing the route information including the IP address of the next router corresponding to the destination internet protocol (IP) address;
an address search table for storing a media access control (MAC) address of the next router corresponding to the IP address of the next router;
a flow search table for storing the action corresponding to the reference conditions including the IP headers of the source and the destination;
a transfer engine for performing a receiving process for storing an input packet received from a network or the connector in the packet buffer, adding the internal header to the packet header and storing the resulting header information in the header memory, and a transmission process for reading the input packet from the packet buffer, producing an output packet from the input packet stored in the packet buffer and the header information stored in the header memory, and outputting the output packet to the connector or the network; and
a search engine for performing an input search process for searching the transfer destination information with reference to the route table based on the header information stored in the header memory, and an output search process for searching the MAC address of the next router with reference to the address search table based on the IP address of the next router determined in the input search process and searching various action including QoS with reference to a flow search table.
According to another aspect of the invention, there is provided a network relaying method for outputting the packets input from the networks, to a transfer destination in a network relaying apparatus comprising at least a network interface connected to the networks, at least a routing processor for routing the packet input from the network interface, a routing manager for managing the internal parts of the system, and a connector for connecting the routing manager and each of a plurality of the routing processors, comprising:
a receiving process for storing the input packet, and storing the header information separately from the input packet by adding the internal header including the input and output port numbers and the QoS control information to the MAC header and the IP (internet protocol) header of the input packet;
an input search process for extracting the destination IP address in the IP header from the header information stored by the receiving process, and searching the transfer destination information including the IP address of the next router based on the destination IP address;
an output search process for extracting the IP address of the next router determined by the input search process, searching the MAC (media access control) address of the next router based on the IP address, searching the action information including the QoS based on the reference conditions including the transfer destination information and the destination information, and storing the searched transfer destination information and the action information in the header information; and
a transmission process for producing an output packet based on the input packet and the header information and outputting the output packet to the connector or the network interface.